feat(elements): Complete and Reset Updates - #3343
Merged
Merged
Conversation
🦋 Changeset detectedLatest commit: 1978150 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
tmilewski
force-pushed
the
elements/complete-step
branch
2 times, most recently
from
May 7, 2024 19:53
532bd7c to
377ba9e
Compare
tmilewski
marked this pull request as ready for review
May 7, 2024 19:56
tmilewski
commented
May 7, 2024
|
|
||
| // TODO: eventually we'll rely on the framework SDK to specify its host router, but for now we'll default to Next.js | ||
| const router = useNextRouter(); | ||
| const isRootPath = path === router.pathname(); |
Member
Author
There was a problem hiding this comment.
This is required, on both Sign Up and Sign In, otherwise, in the case of callbacks, the fallback will show regardless.
tmilewski
commented
May 7, 2024
tmilewski
commented
May 7, 2024
LekoArts
marked this pull request as draft
May 13, 2024 06:50
Co-authored-by: Bryce Kalow <bryce@clerk.dev>
tmilewski
force-pushed
the
elements/complete-step
branch
from
May 13, 2024 19:00
299e17c to
f46886f
Compare
tmilewski
marked this pull request as ready for review
May 13, 2024 19:01
tmilewski
force-pushed
the
elements/complete-step
branch
from
May 13, 2024 19:03
f46886f to
7e74b27
Compare
complete step to Sign Up and Sign In.
12 tasks
* fix(elements): Follow-on machine initialization [SDK-1746] * chore(elements): Add changeset * chore(elements): Remove unnecessary TS comment * chore(elements): Add line item to changeset
tmilewski
commented
May 13, 2024
| }, [clerk, exampleMode, formRef, router]); | ||
|
|
||
| // eslint-disable-next-line react-hooks/exhaustive-deps | ||
| }, [clerk, exampleMode, formRef?.id, !!router]); |
Member
Author
There was a problem hiding this comment.
I saw that formRef and router were causing many unnecessary re-renders. I narrowed the checks down here and in sign up to optimize.
tmilewski
commented
May 13, 2024
|
|
||
| return () => { | ||
| if (factorCtx) { | ||
| if (factorCtx?.getSnapshot().status === 'active') { |
Member
Author
There was a problem hiding this comment.
Ensure we only run this event on an active machine.
LekoArts
approved these changes
May 14, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR contains the results of multiple similar PRs. As-such, this PR ensures the following:
STRATEGY.UNREGISTERevent from being called on stopped machines.xstatetov5.13.0Fixes SDK-1745
Checklist
npm testruns as expected.npm run buildruns as expected.Type of change